package com.feichuang.chineseWoodCarving.util;

/**
 * 线程相关的工具类.
 * 
 * @author chunfeng
 */
public class ThreadUtil {
    /**
     * . 获取线程池组
     * 
     * @return 当前线程的线程池组
     */
    public static ThreadGroup getCurrentThreadGroup() {
        SecurityManager s = System.getSecurityManager();
        ThreadGroup mGroup = null;
        if (s == null) {
            mGroup = Thread.currentThread().getThreadGroup();
        } else {
            mGroup = s.getThreadGroup();
        }
        return mGroup;
    }

}
